<? $usercode = $_COOKIE['memberID'];
 $controllopass= "SELECT * FROM spywall_code LIMIT 0,1";
 $risultato = mysql_query($controllopass,$db) or die(mysql_error());
 $estrazione = mysql_fetch_assoc($risultato);
 $controllo = $estrazione['code'];
 $onecript = "a2dfu8e3asdsad9d3h237230472dsA0dsaGAdga780gas";
 $twocript = $_SERVER['HTTP_HOST'];
 $trecript = "siofnsifo934932cvdfvbdvddifbruiwe0273480475437850t32785t";
 $genera = $onecript.$twocript.$trecript;
  if (md5($genera) != $controllo ) { if ($userid==1) { echo '<b>'._t('_ibdw_spywall_sicurity').'</b>';} } else { 
?>

<?php 
if ($_GET['skin']<>"")
{
$mytemplatepath='templates/'.$_GET['skin'].'/css/';
$imagepath='modules/ibdw/spywall/templates/'.$_GET['skin'].'/css/immagini/';
}
elseif (isset($_COOKIE['skin']))
{
$mytemplatepath='templates/'.$_COOKIE['skin'].'/css/';
$imagepath='modules/ibdw/spywall/templates/'.$_COOKIE['skin'].'/css/immagini/';
}
else
{
$mytemplatepath='templates/uni/css/';
$imagepath='modules/ibdw/spywall/templates/uni/css/immagini/';
}
echo '<link href="modules/ibdw/spywall/'.$mytemplatepath.'style_plug-in.css" rel="stylesheet" type="text/css" />';
$querycontrollo="SELECT Caption,Owner,AllowAlbumView FROM sys_albums WHERE Uri='$namephotoalbum' AND Owner='$usercode'";
$resultquerycontrollo = mysql_query($querycontrollo,$db) or die(mysql_error());
$rowquerycontrollo = mysql_num_rows($resultquerycontrollo);
$rowqueryrow = mysql_fetch_row($resultquerycontrollo);

if ($rowquerycontrollo==0) { 
$queryinserimento="INSERT INTO sys_albums (Caption,Uri,Location,Type,Owner,Status,Date,AllowAlbumView) 
VALUES ('".$namephotoalbum."','".$namephotoalbum."','Undefined','bx_photos','".$usercode."','Active','".time()."','".$privacyalbum."')";

$resultquery = mysql_query($queryinserimento,$db) or die(mysql_error());

}


//v i d e o 

$querycontrollov="SELECT Caption,Owner,AllowAlbumView FROM sys_albums WHERE Uri='$namevideoalbum' AND Owner='$usercode'";
$resultquerycontrollov = mysql_query($querycontrollov,$db) or die(mysql_error());
$rowquerycontrollov = mysql_num_rows($resultquerycontrollov);
$rowqueryrowv = mysql_fetch_row($resultquerycontrollov);

if ($rowquerycontrollov==0) { 

$queryinserimentov="INSERT INTO sys_albums (Caption,Uri,Location,Type,Owner,Status,Date,AllowAlbumView) 
VALUES ('".$namevideoalbum."','".$namevideoalbum."','Undefined','bx_videos','".$usercode."','Active','".time()."','".$privacyalbum."')";

$resultqueryv = mysql_query($queryinserimentov,$db) or die(mysql_error());

}

    $verificaplug = "SELECT Active,status FROM ibdw_urlplug WHERE ID = '1' AND Active = '1' AND status = '1'";
    $eseguiplug = mysql_query($verificaplug);
    $exeplug = mysql_num_rows($eseguiplug);
    
    if($exeplug==1) { $urlplug = 1;} else { $urlplug = 0; }

?>

<script type="text/javascript" src="modules/ibdw/spywall/js/jmini.js" /></script>
<script>
  $jqspywall = jQuery.noConflict();
</script>
<script type="text/javascript" src="plugins/swfupload/swf/swfupload.js"></script>
		  <script type="text/javascript" src="plugins/swfupload/script/js/swfupload.queue.js"></script>
		  <script type="text/javascript" src="plugins/swfupload/script/js/fileprogress.js"></script>
		  <script type="text/javascript" src="plugins/swfupload/script/js/handlers.js"></script>
<script type="text/javascript">		
			function video() {
            $jqspywall("#frammento_video").slideToggle("slow"); 
            $jqspywall("#frammento_foto").slideUp();
            $jqspywall("#frammento_sondaggi").slideUp();
            $jqspywall("#frammento_siti").slideUp();
            $jqspywall("#frammento_url").slideUp();
            $jqspywall("#attendi").slideUp(); }

            function foto() {
            $jqspywall("#frammento_foto").slideToggle("slow");
            $jqspywall("#frammento_video").slideUp();
            $jqspywall("#frammento_sondaggi").slideUp();
            $jqspywall("#frammento_siti").slideUp();
            $jqspywall("#frammento_url").slideUp();
            $jqspywall("#attendi").slideUp(); }

            function sondaggi() {
            $jqspywall("#frammento_sondaggi").slideToggle("slow");
            $jqspywall("#frammento_foto").slideUp();
            $jqspywall("#frammento_video").slideUp();
            $jqspywall("#frammento_siti").slideUp();
            $jqspywall("#frammento_url").slideUp();
            $jqspywall("#attendi").slideUp(); }

            function siti() {
            $jqspywall("#frammento_siti").slideToggle("slow");
            $jqspywall("#frammento_foto").slideUp();
            $jqspywall("#frammento_sondaggi").slideUp();
            $jqspywall("#frammento_video").slideUp();
            $jqspywall("#frammento_url").slideUp();
            $jqspywall("#attendi").slideUp(); }
            
            function url() {
            $jqspywall("#urlspecial").val("<?php echo _t('_ibdw_spywall_urlspecial');?>");
            $jqspywall("#frammento_url").slideToggle("slow");
            $jqspywall("#frammento_foto").slideUp();
            $jqspywall("#frammento_sondaggi").slideUp();
            $jqspywall("#frammento_video").slideUp();
            $jqspywall("#frammento_siti").slideUp();
            $jqspywall("#attendi").slideUp(); }

            function attendi() {
            $jqspywall("#attendi").slideToggle("slow");
            $jqspywall("#frammento_foto").slideUp();
            $jqspywall("#frammento_sondaggi").slideUp();
            $jqspywall("#frammento_video").slideUp();
            $jqspywall("#frammento_siti").slideUp();
            $jqspywall("#frammento_url").slideUp(); }
            
            function lanciaclassic() { 
            $jqspywall("#bloccovideo_tube").fadeOut();
            $jqspywall("#bloccovideo_classic").delay(500).fadeIn(); }
            
           function lanciatube() { 
            $jqspywall("#bloccovideo_classic").fadeOut();
            $jqspywall("#bloccovideo_tube").delay(500).fadeIn();
            }
            
           function lanciaflashfoto() { 
            $jqspywall("#frammento_foto_standard").fadeOut();
            $jqspywall("#frammento_foto_flash").delay(500).fadeIn(); }
            
           function lanciaregularfoto() { 
            $jqspywall("#frammento_foto_flash").fadeOut();
            $jqspywall("#frammento_foto_standard").delay(500).fadeIn();
            } 
</script>
    <?php
    if( $viewavatar=='ON' ) {echo '<div id="cont_upload">';}
    
    else { echo '<div id="cont_uploadnoava">';} 
    ?>             

<?php
           
if ($photo=='ON') 
{ 
 echo '<a href="javascript:foto();"><div id="bottone_generale"><img src="'.$imagepath.'action_upload_photos.png" /><span class="nomeb">'._t('_ibdw_spywall_fotoup').'</span></div></a>'; 
}

if ($video=='ON') 
{ 
 echo '<a href="javascript:video();"><div id="bottone_generale"><img src="'.$imagepath.'action_upload_videos.png" /><span class="nomeb">'._t('_ibdw_spywall_videoup').'</span></div></a>'; 
}

if ($group=='ON') 
{ 
 echo '<a href="m/groups/browse/my&bx_groups_filter=add_group" onclick="attendi();"><div id="bottone_generale"><img src="'.$imagepath.'groups.png" /><span class="nomeb">'._t('_ibdw_spywall_gruppoup').'</span></div> </a> '; 
}

if ($event=='ON') 
{ 
 echo '<a href="m/events/browse/my&bx_events_filter=add_event" onclick="attendi();"><div id="bottone_generale"><img src="'.$imagepath.'events.png" /><span class="nomeb">'._t('_ibdw_spywall_event_name').'</span></div></a> '; 
}

if ($site=='ON') 
{
 echo '<a href="javascript:siti();"><div id="bottone_generale"><img src="'.$imagepath.'globe_green.png" /><span class="nomeb">'._t('_ibdw_spywall_sitoup').'</span></div></a>';
}

if ($poll=='ON')
{
 echo '<a href="javascript:sondaggi();"><div id="bottone_generale"><img src="'.$imagepath.'pls.png" /><span class="nomeb">'._t('_ibdw_spywall_sondaggioup').'</span></div></a>';
}        

if ($ads=='ON')
{
 echo '<a href="ads/my_page/add/" onclick="attendi();"><div id="bottone_generale"><img src="'.$imagepath.'ads.png" /><span class="nomeb">'._t('_ibdw_spywall_adsup').'</span></div></a>';
} 
if ($urlplug=='1')
{
 echo '<a href="javascript:url();"><div id="bottone_generale"><img src="'.$imagepath.'hyperlink.png" /><span class="nomeb">'._t('ibdw_spywall_url').'</span></div></a>';
} 

?>
</div>


<div style="clear:both;"></div>

<?php if ($urlplug=='1') { ?>

<div id="frammento_url"> 

<input id="urlspecial" type="text" onfocus="focuss()" onblur="blurr()" value="<?php echo _t('_ibdw_spywall_urlspecial');?>">
<div id="invia" onclick="inviaurl()"><?php echo _t('_ibdw_spywall_alleg');?></div>
<div class="clear"></div>
</div>

<div id="frammento_exe"></div> 

<script>
function inviaurl() { 
  $('frammento_url').slideUp(200);
  $jqspywall("#attendi").slideDown(200);
  var indirizzo = $("#urlspecial").val();
  $.ajax({
   type: 'POST',
   data: "urlweb=" + indirizzo,
   url: 'modules/ibdw/spywall/inserimentourl.php',
   cache: false,
    success: function(data) {
     $('#frammento_exe').html(data);  
     $jqspywall("#attendi").slideUp(200);
     
    }
});
}

function focuss() { 
  var testo = $("#urlspecial").val();
  if(testo=='<?php echo _t('_ibdw_spywall_urlspecial');?>'){ $("#urlspecial").val('');}
} 

function blurr() { 
  var testo = $("#urlspecial").val();
  if(testo==''){ $("#urlspecial").val('<?php echo _t('_ibdw_spywall_urlspecial');?>');}
}

</script>
<?php } ?>

<?php if ($site=='ON') { ?>
<div id="frammento_siti">
 
   <?php 
  $idtoken = $_COOKIE['memberSession'];
  $estraitoken = "SELECT id,data FROM sys_sessions WHERE id = '$idtoken'";
  $eseguitoken = mysql_query($estraitoken);
    if ($eseguitoken != FALSE) {
      $associazione = mysql_fetch_assoc($eseguitoken);
      $unserialize = unserialize($associazione['data']);
      $tokenfinale = $unserialize[csrf_token]; }
      else { $tokenfinale = 0; }  
  ?>
 
 <form  name="form_site" action="m/sites/browse/my/add" method="post" enctype="multipart/form-data" id="form_site" class="form_advanced">
 <input type="hidden" value="<?php echo $tokenfinale;?>" name="csrf_token" class="form_input_hidden">
 <div class="form_advanced_wrapper form_site_wrapper">
	 <div class="arealink">
 	  <?php echo _t('_ibdw_spywall_inseriscisito');?> <input class="sweblinks" type="text" name="url" />
      <input class="form_input_submit" type="submit" name="submit_form" value="<?php echo _t('_ibdw_spywall_sender'); ?>" />
     </div>
 </div>
 </form>
</div>
<?php } ?>
<?php if ($poll=='ON') { ?>            
<div id="frammento_sondaggi">
 <p class="titbot"><?php echo _t('_ibdw_spywall_inseriscisondaggio'); ?></p>
 
 <form  action="modules/?r=poll/&amp;action=my&amp;mode=add" method="post" name="poll_creation_form" id="poll_creation_form" class="form_advanced">
 <input type="hidden" value="<?php echo $tokenfinale;?>" name="csrf_token" class="form_input_hidden">
 <div class="form_advanced_wrapper poll_creation_form_wrapper">
 <table class="form_advanced_table" cellpadding="0" cellspacing="0">
  <tbody>
   <tr>
    <td class="caption" style="white-space:inherit;">
     <span class="required">*</span> 
     <?php echo _t('_question'); ?> 
    </td>
    <td class="value">
     <div class="clear_both"></div>
     <div class="input_wrapper input_wrapper_text">
      <input  class="form_input_text" type="text" name="question" />
      <div class="input_close input_close_text"></div>
     </div>
     <img class="warn" alt="error" src="templates/base/images/icons/exclamation.png" float_info=" " />
     <div class="clear_both"></div>
    </td>
   </tr>
   <tr>
    <td class="caption" style="white-space:inherit;">
     <span class="required">*</span> 
     <?php echo _t('_bx_poll_answer'); ?> 
    </td>
    <td class="value">
     <div class="clear_both"></div>
     <div class="input_wrapper input_wrapper_text">
      <input multiplyable="true" class="form_input_text" type="text" name="answers[]" value="" />
      <div class="input_close input_close_text"></div>
     </div>
     <img class="warn" alt="error" src="templates/base/images/icons/exclamation.png" float_info=" " />
     <div class="clear_both"></div>
	 <div class="input_wrapper input_wrapper_text">
      <input  deletable="true" class="form_input_text" type="text" name="answers[]" value="" />
      <div class="input_close input_close_text"></div>
     </div>
     <div class="clear_both"></div>
    </td>
   </tr>
   <tr>
    <td class="caption" style="white-space:inherit;">
	Tag: 
    </td>
    <td class="value">
     <div class="clear_both"></div>
     <div class="input_wrapper input_wrapper_text">
      <input  class="form_input_text" type="text" name="tags" />
      <div class="input_close input_close_text"></div>
     </div>
     <img class="info" alt="info" src="templates/base/images/icons/info.gif" float_info="<?php echo _t('_bx_poll_tags_separeted'); ?> />
     <img class="warn" alt="error" src="templates/base/images/icons/exclamation.png" float_info=" " />
     <div class="clear_both"></div>
    </td>
   </tr>
   <tr>
    <td class="caption" style="white-space:inherit;">
     <?php echo _t('_bx_poll_allow_view'); ?>
    </td>
    <td class="value">
     <div class="clear_both"></div>
     <div class="input_wrapper input_wrapper_select">
      <select class="form_input_select" name="allow_view_to">
       <option value="1">Default</option>
	   <option value="2"><?php echo _t('_ibdw_spywall_soloio'); ?></option>
	   <option value="3" selected="selected"><?php echo _t('_public'); ?></option>
	   <option value="4"><?php echo _t('_People'); ?></option>
	   <option value="5"><?php echo _t('_bx_spy_friends'); ?></option>
	  </select>
      <div class="input_close input_close_select"></div>
     </div>
     <img class="warn" alt="error" src="templates/base/images/icons/exclamation.png" float_info=" " />
     <div class="clear_both"></div>
    </td>
   </tr>
   <tr>
    <td class="caption" style="white-space:inherit;">
     <?php echo _t('_bx_poll_allow_comment'); ?> 
    </td>
    <td class="value">
     <div class="clear_both"></div>
     <div class="input_wrapper input_wrapper_select">
      <select  class="form_input_select" name="allow_comment_to">
       <option value="1">Default</option>
	   <option value="2"><?php echo _t('_ibdw_spywall_soloio'); ?></option>
	   <option value="3" selected="selected"><?php echo _t('_public'); ?></option>
	   <option value="4"><?php echo _t('_People'); ?></option>
	   <option value="5"><?php echo _t('_bx_spy_friends'); ?></option>
      </select>
      <div class="input_close input_close_select"></div>
     </div>
     <img class="warn" alt="error" src="templates/base/images/icons/exclamation.png" float_info=" " />
     <div class="clear_both"></div>
    </td>
   </tr>
   <tr>
    <td class="caption" style="white-space:inherit;">
     <?php echo _t('_bx_poll_allow_vote'); ?> 
    </td>
    <td class="value">
     <div class="clear_both"></div>
     <div class="input_wrapper input_wrapper_select">
      <select class="form_input_select" name="allow_vote_to">
       <option value="1">Default</option>
	   <option value="2"><?php echo _t('_ibdw_spywall_soloio'); ?></option>
	   <option value="3" selected="selected"><?php echo _t('_public'); ?></option>
	   <option value="4"><?php echo _t('_People'); ?></option>
	   <option value="5"><?php echo _t('_bx_spy_friends'); ?></option>
      </select>
      <div class="input_close input_close_select"></div>
     </div>
     <img class="warn" alt="error" src="templates/base/images/icons/exclamation.png" float_info=" " />
     <div class="clear_both"></div>
    </td>
   </tr>
   <tr>
    <td class="caption" style="white-space:inherit;">
     <span class="required">*</span> 
     <?php echo _t('_bx_poll_categories'); ?> 
    </td>
    <td class="value">
     <div class="clear_both"></div>
     <div class="input_wrapper input_wrapper_select_box">
      <select multiplyable="true" add_other="true" class="form_input_select" name="Categories[]">
       <option value="" selected="selected"><?php echo _t('_Please_Select_'); ?></option>
	   <option value="Best">Best</option>
	   <option value="Fun">Fun</option>
	   <option value="Other">Other</option>
      </select>
     </div>
     <img class="warn" alt="error" src="templates/base/images/icons/exclamation.png" float_info=" " />
     <div class="clear_both"></div>
    </td>
   </tr>
   <tr>
    <td class="caption" style="white-space:inherit;">
     &nbsp;
    </td>
    <td class="value">
     <div class="clear_both"></div>
     <div class="input_wrapper input_wrapper_submit">
      <div class="button_wrapper">
       <input  class="form_input_submit" type="submit" name="do_submit" value="Send" />
	   <div class="button_wrapper_close"></div>
      </div>
      <div class="input_close input_close_submit"></div>
     </div>
     <img class="warn" alt="error" src="templates/base/images/icons/exclamation.png" float_info=" " />
     <div class="clear_both"></div>
    </td>
   </tr>
  </tbody>
 </table>
</div>
</form>


<script type="text/javascript" language="javascript">
var lang_delete = '<?php echo _t('_delete'); ?>';
var lang_loading = '<?php echo _t('_loading ...'); ?>';
var lang_delete_message = '<?php echo _t('_bx_poll_was_deleted'); ?>';
var lang_make_it = '<?php echo _t('bx_poll_make_it'); ?>';
var lang_you_should_specify_member = '<?php echo _t('_bx_poll_specify_least'); ?>';
var iQSearchWindowWidth  = 400;
var iQSearchWindowHeight = 400;
var dpoll_progress_bar_color = "#88C86A";
var sPageReceiver = 'modules/?r=poll';
</script>

<script src="modules/boonex/poll/js/profile_poll.js" type="text/javascript"></script>


</div>
<?php } 
echo '<div id="attendi"><p style="text-align:center;"><img class="attsa" src="'.$imagepath.'loader.gif">'._t('_ibdw_spywall_second').'</p></div>';
if ($photo=='ON') { ?>

<div id="frammento_foto">
  
  <?php 
  
  $configurazione = "SELECT other FROM spywall_config";
  $esegui = mysql_query($configurazione);
  $numero = mysql_fetch_assoc($esegui);
  
  if ($numero['other'] == 'go') { $aggiorna = "UPDATE spywall_config SET other = '##1##1##1##1##1##1##1##1'"; $esegui = mysql_query($aggiorna); 
  
  $valorereg = $numero['other'];
  $valori = explode("##", $valorereg);
  
  $metphotoregolare = 1;
  $metphotoflash = 1;
  $metvideotube = 1;
  $metvideoflash = 1;
  
  $metodiattiviphoto= 1;
  $metodiattivivideo= 1;
  
  $photoaltri = 1;
  $videoaltri = 1;
  
  
  
  }
  
  else { 
  
  $valorereg = $numero['other'];
  $valori = explode("##", $valorereg);
  
  $metphotoregolare = $valori['0'];
  $metphotoflash = $valori['1'];
  $metvideotube = $valori['2'];
  $metvideoflash = $valori['3'];
  
  $metodiattiviphoto= $valori['4'];
  $metodiattivivideo= $valori['5'];
  
  $photoaltri = $valori['6'];
  $videoaltri = $valori['7'];
  }
  
  ?>
  
  
  <div style="margin-bottom:-15px;margin-top:15px;min-height:104px;">
 <div id="frammento_foto_standard" <?php if($metphotoregolare == 0 ) { echo 'style="display:none;"'; } ?> <?php if($metodiattiviphoto == 2) {echo 'style="display:none;"';} else {'style="display:block !important;"';} ?> >
 <p class="titbot"> <?php echo _t('_ibdw_spywall_inseriscifoto'); ?> </p>
 
 <div id="contenitorealtri">  
  <?php if($photoaltri==1) { echo '<div id="foto_flex"><a href="m/photos/albums/my/add_objects/'.$namephotoalbum.'">'._t('_ibdw_spywall_altrimetodi').'</a></div>'; } ?>
 <?php if($metphotoflash == 1) { echo '<div id="foto_flex"><a href="javascript:lanciaflashfoto();">'._t('_ibdw_spywall_useflash').'</a></div>';}?>
 

 </div>
 <form class="form_advanced" target="upload_file_frame" enctype="multipart/form-data" method="post" action="m/photos/albums/my/add_objects" name="upload" id="photo_upload_form">
                                <input type="hidden" value="accept_upload" name="action" class="form_input_hidden">            <input type="hidden" value="<?php echo $namephotoalbum;?>" name="extra_param_album" class="form_input_hidden">            <input type="hidden" value="fAd9K75MwwCGYBisPFRj" name="csrf_token" class="form_input_hidden">
                    <div class="form_advanced_wrapper photo_upload_form_wrapper">
                                    <table cellspacing="0" cellpadding="0" class="form_advanced_table">
                
                          
                <tbody>
                <tr>
                    <td class="caption">
                        <span class="required">*</span> 
                        Search: 
                    </td>
                    
                    <td class="value">
                        <div class="clear_both"></div>
                                                <div class="input_wrapper input_wrapper_file">
                                        <input type="file" name="file[]" class="form_input_file" onchange="parent.oPhotoUpload.onFileChangedEvent();" multiplyable="true">
                            <div class="input_close input_close_file"></div>
                        </div>
                        
                        
                        <img float_info=" " src="templates/base/images/icons/exclamation.png" alt="error" class="warn">
                        
                        <div class="clear_both"></div>
                    </td>
                </tr>                <tr>
                    <td class="caption">
                        <span class="required">*</span> 
                        &nbsp;
                    </td>
                    
                    <td class="value">
                        <div class="clear_both"></div>
                                                <div class="input_wrapper input_wrapper_checkbox">
                                        <input type="checkbox" id="photo_upload_form_input_agree" name="agree" class="form_input_checkbox" onchange="parent.oPhotoUpload.onFileChangedEvent();"><label for="photo_upload_form_input_agree"><?php echo _t('_ibdw_spywall_iveright');?></label>
                            <div class="input_close input_close_checkbox"></div>
                        </div>
                        
                        
                        <img float_info=" " src="templates/base/images/icons/exclamation.png" alt="error" class="warn">
                        
                        <div class="clear_both"></div>
                    </td>
                </tr>                    <tr>
                        <td colspan="2" class="colspan">
                            <div class="clear_both"></div>
                            
                            
                                                    <div class="input_wrapper input_wrapper_submit">
                                        <div class="button_wrapper">
                <input type="submit" value="<?php echo _t('_ibdw_spywall_continue');?>" name="upload" class="form_input_submit" disabled="disabled" onclick="return parent.oPhotoUpload._loading(true);">
                <div class="button_wrapper_close"></div>
            </div>
                            <div class="input_close input_close_submit"></div>
                        </div>
                            
                            
                            <img float_info=" " src="templates/base/images/icons/exclamation.png" alt="error" class="warn">
                            
                            <div class="clear_both"></div>
                        </td>
                    </tr>
                
                </tbody>

            </table>
                    </div>
                </form>
 
 
 </div>
 <div id="frammento_foto_flash" <?php if($metphotoflash == 0 ) { echo 'style="display:none;"'; } ?> <?php if($metodiattiviphoto == 1 ) { echo 'style="display:none;"'; } else { 'style="display:block !important;"'; } ?> >
 <p class="titbot"> <?php echo _t('_ibdw_spywall_inseriscifoto'); ?></p>
 <div id="contenitorealtri">
 <?php if($photoaltri==1) { echo '<div id="foto_flex"><a href="m/photos/albums/my/add_objects/'.$namephotoalbum.'">'._t('_ibdw_spywall_altrimetodi').'</a></div>'; } ?>
 <?php if($metphotoregolare == 1 ) { echo '<div id="foto_flex"><a href="javascript:lanciaregularfoto();">Use Regular</a></div>';}?> 
 
 
 </div>
 
 <iframe style="display:none;" name="upload_file_frame"></iframe>
  <script src="modules/boonex/photos/js/upload.js" type="text/javascript" language="javascript"></script>
  <script type="text/javascript">
   var oPhotoUpload = new BxPhotoUpload({
             iOwnerId: <?=$usercode?>
            });
  </script>

	<input  class="form_input_hidden" type="hidden" name="action" value="accept_multi_upload" />
    <div class="form_advanced_wrapper form_advanced_wrapper">
    <table  class="form_advanced_table" cellpadding="0" cellspacing="0">
     <tbody >
      <tr>
       <td class="colspan" colspan="2">
        <div class="clear_both"></div>
        <div class="input_wrapper input_wrapper_custom">
         <link href="plugins/swfupload/css/default.css" rel="stylesheet" type="text/css" />
		  
      
      
      <script type="text/javascript">
			var bx_swf_uploaders;

			if ('false' == 'true') 
			{
			 bxInitSwfUploaders();
			} 
			else 
			{
			 addEvent( window, 'load', function() { bxInitSwfUploaders() } );
			}
			/*window.onload = function()*/
    		function bxInitSwfUploaders() {
			bx_swf_uploaders = new SWFUpload({
			// Backend Settings
			upload_url: "m/photos/albums/my/add_objects",
			post_params : {"action": "accept_multi_files", "oid": "<?=$usercode?>" , "extra_param_album": "<?php echo $namephotoalbum; ?>"},

			// File Upload Settings
			file_size_limit : "209715200",
			file_types : "*.jpg;*.png;*.gif",
			file_types_description : "All Files",
			file_upload_limit : "10",
			file_queue_limit : "5",


			// Event Handler Settings (all my handlers are in the Handler.js file)
			file_dialog_start_handler : fileDialogStart,
			file_queued_handler : fileQueued,
			file_queue_error_handler : fileQueueError,
			file_dialog_complete_handler : fileDialogComplete,
			upload_start_handler : uploadStart,
			upload_progress_handler : uploadProgress,
			upload_error_handler : uploadError,
			upload_success_handler : uploadSuccess,
			upload_complete_handler : uploadComplete,


			// Button Settings
			button_window_mode: "opaque",
			button_image_url : "plugins/swfupload/images/XPButtonUploadText_61x22.png",
			button_placeholder_id : "spanButtonPlaceholder",
			button_width: 75,
			button_height: 25,
            button_text_top_padding : 4, 
            button_text : "<span class=\"swf_center\"> Select File </span>",
            button_text_style : ".swf_center { text-align:center;font-family:Verdana,Arial;color:#333;font-size:11px; }", 

			
			// Flash Settings
			flash_url : "plugins/swfupload/swf/swfupload.swf",
/*
			swfupload_element_id : "flashUI2",		// Setting from graceful degradation plugin
			degraded_element_id : "degradedUI2",	// Setting from graceful degradation plugin
*/

			custom_settings : {
				progressTarget : "fsUploadProgresss",
				cancelButtonId : "btnCancell"
			},


			// Debug Settings
			debug: false
		});

	 }
</script>

	<div id="content">
 	 <form id="form1" action="m/photos/albums/my/add_objects" method="post" enctype="multipart/form-data" style="margin-bottom:10px;">
     <div>
      <div class="fieldset flash" id="fsUploadProgresss"></div>
      <div>
       <span id="spanButtonPlaceholder"></span>
       <div class="button_wrapper">
       <input id="btnCancell" type="button" value="Cancel Upload" onclick="cancelQueue(bx_swf_uploaders);" disabled="disabled" class="form_input_submit" />
       <div class="button_wrapper_close"></div>
      </div>
     </div>
    </div>
    </form>
    <div id="accepted_files_blocks"></div>
   </div>
   <div class="input_close input_close_custom"></div>
  </div>
  <img class="warn" alt="error" src="templates/base/images/icons/exclamation.png" float_info=" " />
  <div class="clear_both"></div>
  </td>
 </tr>
</tbody>
</table>
</div>

<div style="background-color:#ffdada;" id="accepted_files_blocks"></div>
<div id="photo_success_message" style="display:none;">
<div class="MsgBox" id="1266406470">
 <table class="MsgBox" cellpadding="0" cellspacing="0">
  <tr>
   <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_lt.png" alt="" /></td>
   <td class="msgbox_top_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
   <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_rt.png" alt="" /></td>
  </tr>
  <tr>
   <td class="msgbox_left_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
   <td class="msgbox_content">
    <div class="msgbox_text"><?php echo _t('_bx_photos_upl_succ') ?></div>
   </td>
   <td class="msgbox_right_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
  </tr>
  <tr>
   <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_lb.png" alt="" /></td>
   <td class="msgbox_bottom_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
   <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_rb.png" alt="" /></td>
  </tr>
 </table>
</div>
</div>

<div id="photo_failed_file_message" style="display:none;">
<div class="MsgBox" id="1266406470">
 <table class="MsgBox" cellpadding="0" cellspacing="0">
  <tr>
   <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_lt.png" alt="" /></td>
   <td class="msgbox_top_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
   <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_rt.png" alt="" /></td>
  </tr>
  <tr>
   <td class="msgbox_left_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
   <td class="msgbox_content">
    <div class="msgbox_text"><?php echo _t('_bx_photos_upl_file_err'); ?></div>
   </td>
   <td class="msgbox_right_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
  </tr>
  <tr>
   <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_lb.png" alt="" /></td>
   <td class="msgbox_bottom_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
   <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_rb.png" alt="" /></td>
  </tr>
 </table>
</div>
</div>

<div id="photo_failed_message" style="display:none;">
<div class="MsgBox" id="1266406470">
 <table class="MsgBox" cellpadding="0" cellspacing="0">
  <tr>
   <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_lt.png" alt="" /></td>
   <td class="msgbox_top_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
   <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_rt.png" alt="" /></td>
  </tr>
  <tr>
   <td class="msgbox_left_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
   <td class="msgbox_content">
    <div class="msgbox_text"><?php echo _t('_bx_photos_upl_file_err'); ?></div>
   </td>
   <td class="msgbox_right_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
  </tr>
  <tr>
   <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_lb.png" alt="" /></td>
   <td class="msgbox_bottom_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
   <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_rb.png" alt="" /></td>
  </tr>
 </table>
</div>
</div>

<div id="photo_embed_failed_message" style="display:none;">
<div class="MsgBox" id="1266406470">
 <table class="MsgBox" cellpadding="0" cellspacing="0">
  <tr>
   <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_lt.png" alt="" /></td>
   <td class="msgbox_top_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
   <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_rt.png" alt="" /></td>
  </tr>
  <tr>
   <td class="msgbox_left_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
   <td class="msgbox_content">
    <div class="msgbox_text"><?php echo _t('_bx_photos_emb_err'); ?></div>
   </td>
   <td class="msgbox_right_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
  </tr>
  <tr>
   <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_lb.png" alt="" /></td>
   <td class="msgbox_bottom_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
   <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_rb.png" alt="" /></td>
  </tr>
 </table>
</div>
</div>
</div>
</div>
</div>
<?php } ?>
    <?php 
    $richiestanome="SELECT VALUE FROM sys_options WHERE Name='bx_videos_profile_album_name'";
    $resultrichiestanome = mysql_query($richiestanome,$db) or die(mysql_error());
    $rowrichiestanome = mysql_fetch_row($resultrichiestanome); 
    ?>
    <?php if ($video=='ON') { ?>
    <div id="frammento_video">
    <div id="box_video" style="min-height:77px;position:relative;top:16px;">
     
     <div id="bloccovideo_tube" <?php if($metvideotube == 0 ) { echo 'style="display:none;"'; } ?> <?php if($metodiattivivideo == 2 ) { echo 'style="display:none;"'; } else { 'style="display:block !important;"'; } ?>>
     <p class="titbot"><?php echo _t('_ibdw_spywall_inseriscivideo'); ?> </p>
     <div id="contenitorealtri">
     <?php if($metvideoflash == 1 ) { echo '<div id="foto_flex"><a href="javascript:lanciaclassic();">'._t('_ibdw_spywall_uploadfrompc').'</a></div>';}?>
     <?php if($videoaltri==1) { echo '<div id="foto_flex"><a href="m/videos/albums/my/add_objects/'.$namevideoalbum.'">'._t('_ibdw_spywall_altrimetodi').'</a></div>'; } ?> 
      </div>
     <div id="bloccotubox">
     <form class="form_advanced" target="upload_file_frame" enctype="multipart/form-data" method="post" action="m/videos/albums/my/add_objects" 
name="embed" id="video_upload_form">
                                
                                <input type="hidden" value="accept_embed" name="action" class="form_input_hidden">            
                                
                                <input type="hidden" value="<?php echo $namevideoalbum;?>" name="extra_param_album" class="form_input_hidden">           
                                
                                 <input type="hidden" value="k2J3/SY7BdEZjV&amp;RZHrB" name="csrf_token" class="form_input_hidden">
                    
                        <div style="float:left;font-size:12px;height:57px;margin-left:12px;margin-top:5px;width:356px;">
                        
                        <input type="text" id="textyoutube" name="embed" class="form_input_text" onkeyup="parent.oVideoUpload.checkEmbed()" 
                                        onchange="parent.oVideoUpload.checkEmbed()" onclick="parent.oVideoUpload.checkEmbed();resettaci()"
                                        value="<?echo _t('_ibdw_spywall_linktoyoutube');?>" 
                                        style="background-color:#FFFFFF;border:1px solid #D3DEE4;color:#666666;
                                        font-size:11px;height:22px;margin-bottom:3px;padding-left:5px;width:336px;" onblur="if (this.value==''){reimposta()};">
                                        <script>
                                              function resettaci() {
                                              $jqspywall("#textyoutube").val(""); }
                                              
                                              function reimposta() {
                                              $jqspywall("#textyoutube").val("<?echo _t('_ibdw_spywall_linktoyoutube');?>"); }
                                        </script>  
                        <br/>
                        <span style="font-size:10px;"><?php echo _t('_ibdw_spywall_example');?>: <?php echo _t('_ibdw_spywall_exlinkyb');?> </span>  
                        </div>   
                        
                <div>          
                <input type="submit" value="<?php echo _t('_ibdw_spywall_continue');?>" name="shoot" class="form_input_submit" disabled="disabled" onclick="return parent.oVideoUpload._loading(true); shVideoEnableSubmit(false);" style="margin-top:5px;">
                </div>
                </form>
    <div style="clear:both">  </div>
    </div> </div>
    <div id="bloccovideo_classic" <?php if($metvideoflash == 0 ) { echo 'style="display:none;"'; } ?> <?php if($metodiattivivideo == 1 ) { echo 'style="display:none;"'; } else { 'style="display:block !important;"'; } ?> >
    <p class="titbot">
    <?php echo _t('_ibdw_spywall_inseriscivideo'); ?></p>
    <div id="contenitorealtri"> 
    <?php if($metvideotube == 1 ) { echo '<div id="foto_flex"><a href="javascript:lanciatube();">'._t('_ibdw_spywall_uploadfromyoutube').'</a></div>'; } ?>
    </div> 
     <iframe style="display:none;" name="upload_file_frame"></iframe>
      <script src="modules/boonex/videos/js/upload.js" type="text/javascript" language="javascript"></script>
      <script type="text/javascript">
       var oVideoUpload = new BxVideoUpload({
       iOwnerId: <?=$usercode?>
       });
      </script>

	  <input class="form_input_hidden" type="hidden" name="action" value="accept_multi_upload" />
      <div class="form_advanced_wrapper form_advanced_wrapper">
      <table class="form_advanced_table" cellpadding="0" cellspacing="0">
       <tbody>
        <tr>
         <td class="colspan" colspan="2">
          <div class="clear_both"></div>
          <div class="input_wrapper input_wrapper_custom">
           <link href="plugins/swfupload/css/default.css" rel="stylesheet" type="text/css" />
		   <script type="text/javascript">

			var bx_swf_uploader;
			if ('false' == 'true') 
			{
			 bxInitSwfUploader();
		    } 
			else 
			{
			 addEvent( window, 'load', function() { bxInitSwfUploader() } );
			}

	/*window.onload = function()*/
    function bxInitSwfUploader() {
		bx_swf_uploader = new SWFUpload({

			// Backend Settings
			upload_url: "m/videos/albums/my/add_objects",
			post_params : {"action": "accept_multi_files", "oid": "<?=$usercode?>" , "extra_param_album": "<?php echo $namevideoalbum; ?>" },

			// File Upload Settings
			file_size_limit : "209715200",
			file_types : "*.avi;*.flv;*.mpg;*.wmv;*.mp4;*.m4v;*.mov;*.divx;*.xvid",
			file_types_description : "Video Files",
			file_upload_limit : "10",
			file_queue_limit : "5",

			// Event Handler Settings (all my handlers are in the Handler.js file)
			file_dialog_start_handler : fileDialogStart,
			file_queued_handler : fileQueued,
			file_queue_error_handler : fileQueueError,
			file_dialog_complete_handler : fileDialogComplete,
			upload_start_handler : uploadStart,
			upload_progress_handler : uploadProgress,
			upload_error_handler : uploadError,
			upload_success_handler : uploadSuccess,
			upload_complete_handler : uploadComplete,

			// Button Settings
			button_window_mode: "opaque",
			button_image_url : "plugins/swfupload/images/XPButtonUploadText_61x22.png",
			button_placeholder_id : "spanButtonPlaceholders",
			button_width: 75,
			button_height: 25,
            button_text_top_padding : 4, 
            button_text : "<span class=\"swf_center\">Select File</span>",
            button_text_style : ".swf_center { text-align:center;font-family:Verdana,Arial;color:#333;font-size:11px; }", 

			// Flash Settings
			flash_url : "plugins/swfupload/swf/swfupload.swf",
/*
			swfupload_element_id : "flashUI2",		// Setting from graceful degradation plugin
			degraded_element_id : "degradedUI2",	// Setting from graceful degradation plugin
*/

			custom_settings : {
				progressTarget : "fsUploadProgress",
				cancelButtonId : "btnCancel"
			},

			// Debug Settings
			debug: false
		});
	 }
    </script>

    <div id="content">
     <form id="form1" action="m/videos/albums/my/add_objects" method="post" enctype="multipart/form-data" style="margin-bottom:10px;">
      <div>
       <div class="fieldset flash" id="fsUploadProgress"></div>
        <div>
         <span id="spanButtonPlaceholders"></span>
         <div class="button_wrapper">
          <input id="btnCancel" type="button" value="Cancel Upload" onclick="cancelQueue(bx_swf_uploader);" disabled="disabled" class="form_input_submit" />
	      <div class="button_wrapper_close"></div>
         </div>
        </div>
       </div>
       </form>
       <div id="accepted_files_blocks"></div>
      </div>
	  <div class="input_close input_close_custom"></div>
	 </div>
	 <img class="warn" alt="error" src="templates/base/images/icons/exclamation.png" float_info=" " />
     <div class="clear_both"></div>
    </td>
   </tr>
  </tbody>
 </table>
</div>

<div style="background-color:#ffdada;" id="accepted_files_blocks"></div>
<div id="video_success_message" style="display:none;"><div class="MsgBox" id="1266485442">

<table class="MsgBox" cellpadding="0" cellspacing="0">
 <tr>
  <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_lt.png" alt="" /></td>
  <td class="msgbox_top_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
  <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_rt.png" alt="" /></td>
 </tr>
 <tr>
  <td class="msgbox_left_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
  <td class="msgbox_content">
   <div class="msgbox_text"><?php echo _t('_bx_videos_upl_succ'); ?></div>
  </td>
  <td class="msgbox_right_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
 </tr>
 <tr>
  <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_lb.png" alt="" /></td>
  <td class="msgbox_bottom_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
  <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_rb.png" alt="" /></td>
 </tr>
</table>
</div>
</div>

<div id="video_failed_file_message" style="display:none;">
 <div class="MsgBox" id="1266485442">
  <table class="MsgBox" cellpadding="0" cellspacing="0">
   <tr>
    <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_lt.png" alt="" /></td>
	<td class="msgbox_top_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
	<td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_rt.png" alt="" /></td>
   </tr>
   <tr>
    <td class="msgbox_left_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
	<td class="msgbox_content"><div class="msgbox_text"><?php echo _t('_bx_videos_upl_file_err'); ?></div></td>
	<td class="msgbox_right_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
   </tr>
   <tr>
	<td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_lb.png" alt="" /></td>
	<td class="msgbox_bottom_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
	<td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_rb.png" alt="" /></td>
   </tr>
  </table>
</div>
</div>

<div id="video_failed_message" style="display:none;"><div class="MsgBox" id="1266485442">
 <table class="MsgBox" cellpadding="0" cellspacing="0">
  <tr>
   <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_lt.png" alt="" /></td>
   <td class="msgbox_top_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
   <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_rt.png" alt="" /></td>
  </tr>
  <tr>
   <td class="msgbox_left_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
   <td class="msgbox_content"><div class="msgbox_text"><?php echo _t('_bx_videos_upl_file_err'); ?></div></td>
   <td class="msgbox_right_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
  </tr>
  <tr>
   <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_lb.png" alt="" /></td>
   <td class="msgbox_bottom_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
   <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_rb.png" alt="" /></td>
  </tr>
 </table>
</div>
</div>

<div id="video_embed_failed_message" style="display:none;"><div class="MsgBox" id="1266485442">
 <table class="MsgBox" cellpadding="0" cellspacing="0">
  <tr>
   <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_lt.png" alt="" /></td>
   <td class="msgbox_top_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
   <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_rt.png" alt="" /></td>
  </tr>
  <tr>
   <td class="msgbox_left_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
   <td class="msgbox_content"><div class="msgbox_text"><?php echo _t('_bx_videos_emb_err'); ?></div></td>
   <td class="msgbox_right_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
  </tr>
  <tr>
   <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_lb.png" alt="" /></td>
   <td class="msgbox_bottom_side"><img src="templates/tmpl_uni/images/spacer.gif" alt="" /></td>
   <td class="msgbox_corner"><img src="templates/base/images/msgbox_cor_rb.png" alt="" /></td>
  </tr>
 </table>
</div>
</div>
</div>
</div>
</div>
<?php } ?>
   <div id="accepted_files_block"></div>
   <div class="input_close input_close_custom"></div>
   <div class="clear_both"></div>
   
<div style="background-color:#ffdada;" id="accepted_files_block"></div>

<?php } ?>